<?php if(!IS_AJAX){?>

<include file="Public:header" />
<div class="row">

<div class="col-sm-12 col-md-12 col-lg-12">
    
    <div class="panel">
      <header class="panel-heading"> 搜索</header>
      <div class="panel-body">
        <form id="ajaxdatalistform" action="">
            <div>
                <select class="form-control m-bot15" name="type" onchange="$('#ajaxdatalistform').submit();">
                    <option value="0">全部</option>
                    <option value="1">直属商家</option>
                    <option value="2">业务员商家</option>
                    <option value="3">服务商商家</option>
                </select>
            </div>
          <div class="input-group m-bot15">
            <input type="text" name="keywords" class="form-control">
            <span class="input-group-btn">
            <button type="button" onClick="$('#ajaxdatalistform').trigger('submit');" class="btn btn-default"><i class="fa fa-search"></i></button>
            </span> </div>
        </form>
       
      </div>
    </div>
  </div>
  <div class="col-sm-12 col-md-12 col-lg-12">
    <section class="panel">
      <div class="panel-body">
        <table class="table-bordered table" width="100%" border="0" cellspacing="0" cellpadding="0">
 <thead>
 <tr>
        <tr>
                <td height="21" align="center">ID</td>
                <td align="center">商家</td>
                <td align="center">负责人</td>
                <td align="center">联系电话</td>
                <td align="center">营业额</td>
                <td align="center">应让利金额（积分）</td>
                <td align="center">已让利金额</td>
                <td align="center">剩余让利金额</td>
                <td align="center">让利状态</td>
            </tr>
</thead>
          <tbody class="ajaxdatalist" id="ajaxdatalist">
            <?php }?>
            <?php if(IS_AJAX){?>
            <!-- 数据主体 -->
        <notempty name="list">
         <volist name="list" id="vo">
              <tr class="data_list">
                    <td align="center">{$vo.number}</td>
                    <td>{$vo.shop}</td>
                    <td align="center">{$vo.contacts}</td>
                    <td>{$vo.sphone}</td>
                    <td>{$vo.money}</td>
                    <td>{$vo.discount}</td>
                    <td>{$vo.discounted}</td>
                    <td align="center">{$vo.discounting}</td>
                    <td align="center">
                        <eq name="vo.status" value="1">
                            <span class="status1 status_btn" field="status,{$vo.id}"></span>
                        <else/>
                            <span class="status0 status_btn" field="status,{$vo.id}"></span>
                        </eq>
                    </td>
                </tr>
         </volist>
         <else/>
            <tr>
                <td colspan="9" align="center">暂无商家信息</td>
            </tr>
        </notempty>
            <?php }?>
            <!-- 数据主体结束 -->
            <?php if(!IS_AJAX){?>
          </tbody>
        </table>
        <div id="ajaxdatalistpages"></div>
      </div>
    </section>
  </div>
  
</div>
<include file="Public:footer" />
<style>
    .option a.btn{margin-top:5px;}
</style>
<script>
</script>
</body></html><?php }?>

